-
Notifications
You must be signed in to change notification settings - Fork 788
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
exclude removed reactables #1750
Conversation
Running the example code in the related issue, with this PR, causes this error when I follow the instructions in that issue:
This looks to be the same result as when I tested with |
Bit premature @davep |
D'oh! Could have sworn I'd seen a review request come in on this one. Apologies, getting stuff mixed up! |
No worries. Ready now. |
Hey look, it works now! ;-) |
src/textual/message_pump.py
Outdated
@@ -123,6 +123,20 @@ def log(self) -> Logger: | |||
""" | |||
return self.app._logger | |||
|
|||
@property | |||
def is_attached(self) -> bool: | |||
"""Check the node is attached to the app via the DOM.""" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As a property, perhaps this would be better worded more like "Is the node attached to the app via the DOM?"
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just the type of thing I would say :')
Fixes #1714
When calling
switch_screen
a screen is removed, but the watchers in the header were called after the DOM had been deleted.